﻿using Entites;
using Microsoft.AspNetCore.Razor.TagHelpers;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;

namespace CandyAdmin.Comon.Tags
{
    public class submtTagHelper:TagHelper
    {
        public Menu menu { get; set; }
        public override void Process(TagHelperContext context, TagHelperOutput output)
        {
            base.Process(context, output);
            output.TagName = "section";
            output.Content.SetHtmlContent
                (
                $@"<li>  <a onclick='xadmin.add_tab({menu.Name}, { menu.Path})'> < i class='iconfont'>{ menu.Icon.Info};</i><cite>{menu.Name}</cite> </a> </li>"

            );
            
        }

    }
}
